package com.example.demo.service.Imp;


import com.example.demo.dao.DataMapper;
import com.example.demo.model.Data;
import com.example.demo.service.DataService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
/**
 * 编写者：施皓
 * 编写时间：2019.5.28
 */
@Service
public class DataServiceImp implements DataService {

    @Autowired
    private DataMapper dataMapper;
    @Override
    public Data DataKey(Integer did){

        return dataMapper.DataKey(did);
    }

    @Override
    public List<Data> getsex() {
        System.out.println("执行角色类型SQL语句");
        return dataMapper.getsex();
    }

    @Override
    public List<Data> getAllData() {
        return dataMapper.getAllData();
    }

    @Override
    public int delData(Integer did) {
        return dataMapper.delData(did);
    }

    @Override
    public int insertData(Data datamodel) {

        return dataMapper.insertData(datamodel);
    }

    @Override
    public int updateData(Data datamodel) {

        return dataMapper.updateData(datamodel);
    }
}
